<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>

  <div id="app">
    <!-- 单选框 -->
    <label for="agree">
      <input type="checkbox" id="agree" v-model="isAgree">同意协议
    </label>
    <h2>单选框:{{isAgree}}</h2>


    <!-- 多选框 -->
    <div class="hobbies">
      <h2>请选择你的爱好</h2>
     <label for="sing">
      <input type="checkbox" id="sing" v-model="hobbies" value="唱">唱
     </label>
     <label for="dance">
      <input type="checkbox" id="dance" v-model="hobbies" value="跳">跳
     </label>
     <label for="rap">
      <input type="checkbox" id="rap" v-model="hobbies" value="rap">rap
     </label>
     <label for="ball">
      <input type="checkbox" id="ball" v-model="hobbies" value="篮球">篮球
     </label>
   <h2>爱好:{{hobbies}}</h2>
    </div>
    

  </div>
  
  <script src="../lib/vue.global.js"></script>
  <script>
    // 1.创建app
    const app = Vue.createApp({
      // data: option api
      data() {
        return {
          isAgree: false,
          hobbies: []
        }
      },
    })

    // 2.挂载app
    app.mount("#app")
  </script>
</body>
</html>